Release 10.1A: OpenEdge Development:
Programming Interfaces


Option 1: instantiate Automation object by name

This option creates a connection to a new instance of a specified Automation object, launching the Server if necessary. For top-level Automation objects (such as Excel.Application), this option usually launches a new instance of the Server, unlike for lower-level objects (such as Excel.Sheet, which use the instance created by a top-level object):

DEFINE VARIABLE hExcelObject AS COM-HANDLE
CREATE "Excel.Application" hExcelObject. 

Figure 15–1 summarizes the basic logic for this option.

Figure 15–1: Automation connection option 1

Note: This option is equivalent to the Visual Basic CreateObject(class) or GetObject("",class) function call.


Copyright © 2005 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095